package com.jrx.anytxn.transaction.service;

import com.jrx.anytxn.common.exception.TxnException;
import com.jrx.anytxn.transaction.bean.TransferBean;
import com.jrx.anytxn.transaction.bean.TransferSaveBean;

/**
 * @program: anytxn-cf-transaction
 * @description: 账户类型转列策略
 * @author: xiaoyu.jing
 * @date: 2019-11-15 19:30
 **/
public interface ITransferTypeStrategy<T> {

    /**
     * 账户外转列处理 会计状态升级，转表外，五级分类升级
     * @param transferBean
     * @return
     * @throws TxnException
     */
    TransferSaveBean transferOut(TransferBean<T> transferBean) throws TxnException;


    /**
     * 账户内转列出处理 会计状态降级，转应计，五级分类降级
     * @param transferBean
     * @return
     * @throws TxnException
     */
    TransferSaveBean transferIn(TransferBean<T> transferBean) throws TxnException;


}
